package com.itheima.ai.mapper;


import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.itheima.ai.entity.po.SpringAiChatRecord;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface SpringAiChatRecordMapper extends BaseMapper<SpringAiChatRecord> {

    @Select("SELECT id FROM spring_ai_chat_record  WHERE type = #{type} ORDER BY create_time DESC")
    List<String> findConversationIds(@Param("type") String type);
}